﻿<UserControl x:Class="Zcu.PanelComposer.Views.Pages.SolutionProjectsView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:ht="http://helixtoolkit.codeplex.com"
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="300">
    <DockPanel>
        <Label x:Name="DisplayName" Content="Title" FontSize="16" DockPanel.Dock="Top" />

        <DataGrid x:Name="SolutionProject" SelectedItem="{Binding SelectedSolutionProject}" AutoGenerateColumns="False" 
                  CanUserAddRows="False" CanUserDeleteRows="False" IsReadOnly="True" MinHeight="100"
                  Margin="0 0 0 10" DockPanel.Dock="Bottom">
            <DataGrid.Columns>
                <DataGridTextColumn Header="Name of Project" Binding="{Binding Path=Project.DisplayName}" SortMemberPath="Project.DisplayName" Width="*" />
                <DataGridTextColumn Header="X Translate" Binding="{Binding X_Translate}" SortMemberPath="X_Translate" Width="0.2*" />
                <DataGridTextColumn Header="Y Translate" Binding="{Binding Y_Translate}" SortMemberPath="Y_Translate" Width="0.2*" />
                <DataGridTextColumn Header="Z Translate" Binding="{Binding Z_Translate}" SortMemberPath="Z_Translate" Width="0.2*" />
            </DataGrid.Columns>
        </DataGrid>

        <GroupBox Header="Action" Width="200" DockPanel.Dock="Right">
            <Grid Margin="5">
                <Grid.RowDefinitions>
                    <RowDefinition Height="35" />
                    <RowDefinition Height="35" />
                    <RowDefinition Height="35" />
                    <RowDefinition Height="35" />
                    <RowDefinition Height="35" />
                    <RowDefinition />
                </Grid.RowDefinitions>

                <Button Grid.Row="0" x:Name="ActiveProjectAction" Content="Active project" Margin="0 3" />
                <Button Grid.Row="1" x:Name="EditSolutionProjectAction" Content="Edit link" Margin="0 3" />
                <Button Grid.Row="2" x:Name="NewSolutionProjectAction" Content="New link" Margin="0 3" />
                <Button Grid.Row="3" x:Name="DeleteSolutionProjectAction" Content="Delete link" Margin="0 3"  />
            </Grid>
        </GroupBox>

        <Grid>
            <ht:HelixViewport3D ZoomExtentsWhenLoaded="True">

                <!-- Remember to add light to the scene -->
                <ht:DefaultLights ShowLights="True" />
                <!--<ht:SunLight/>-->

                <!-- The content of this visual is defined in MainViewModel.cs -->
                <ModelVisual3D Content="{Binding Model}" />

                <!-- You can also add elements here in the xaml -->
                <ht:GridLinesVisual3D Width="1024" Length="1024" MinorDistance="10" MajorDistance="100" Thickness="1"/>

            </ht:HelixViewport3D>
        </Grid>

    </DockPanel>
</UserControl>
